<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <title>Document</title>
    <style>
      body {
        font-family: sans-serif;
      }
      li[class] {
        font-size: 120%;
      }

      li[class="a"] {
        background-color: yellow;
      }

      li[class~="a"] {
        color: red;
      }
    </style>
  </head>
  <body>
    <h1>Attribute presence and value selectors</h1>
    <ul>
      <li>Item 1</li>
      <li class="a">Item 2</li>
      <li class="a b">Item 3</li>
      <li class="ab">Item 4</li>
    </ul>
  </body>
</html>
